package main

import (
    "fmt"
    "hitme/go-api/models"
    "hitme/go-api/modules/db"
    "hitme/go-api/modules/engine"
)

func main()  {
    engine.Default().AddConfigFromYAML("./config.yml")

    // 执行迁移
    db.MysqlDB.AutoMigrate(&models.PhotoSpec{})
    db.MysqlDB.AutoMigrate(&models.User{})
    db.MysqlDB.AutoMigrate(&models.Order{})
    db.MysqlDB.AutoMigrate(&models.FeedBack{})
    db.MysqlDB.AutoMigrate(&models.Idcard{})
    db.MysqlDB.AutoMigrate(&models.OssFile{})

    fmt.Println("执行完毕")
}